import React, { Component } from 'react'
import { Table } from 'antd'
import {TablePaginationConfig} from 'antd/lib/table'
import "../style.scss"

 export interface IPageination extends TablePaginationConfig{

}
interface IProps {
    columns: any[],
    dataSource: any[],
    loading?:boolean,
    tableKey?:string,
    expandable?:any,
    scroll?:any,
    pageChange?:(page:number,pageSize?:number) =>  void | undefined,
    total?:number,
    selectRow?:(record:any) => void,
    search?:(params:any) => void,
    label?:string,
    placeholder?:string,
}
interface IStates {
    dataSource ?: any[],
    columns:any[],
    loading ?: boolean,
    pageConfig?:IPageination,
    selectedKey?:any[]
}

export default class BaseTable extends Component<IProps, IStates> {
    constructor(props:IProps){
        super(props)
        this.state = {
            columns:[]
        }
    }
    public renderTable() {
        return (
            <div className="table">
                <Table>
                </Table>
            </div>
        )
    }
    public render() {
        return (
            <React.Fragment>
                 {this.renderTable()}
            </React.Fragment>
        )
    }
}